! 1d 2d first

      end if
    else
      if (trim(stack(stack_pointer - 1) % d1 % dimNames(1)) == &
          trim(stack(stack_pointer) % d2 % dimNames(1))) then

! 1d 2d second
